package com.xinghou.platform.dao.main;

import java.util.List;

import org.springframework.dao.DataAccessException;

import com.xinghou.platform.entity.resp.ShareInfoPhotoResp;
import com.xinghou.platform.model.main.SharedCardImage;

/**
 * @author liuwei.wen
 *
 */
public interface SharedCardImageDAO {

	    public SharedCardImage getSharedCardImageByid(Integer id) throws DataAccessException;
		
		public int updateSharedCardImage(SharedCardImage sharedCardImage) throws DataAccessException;
			
		public int saveSharedCardImage(SharedCardImage sharedCardImage) throws DataAccessException;
		
		public List<ShareInfoPhotoResp> getSharedCardImagelist(int cardid ) throws DataAccessException;
		
		/**
		 * 获得分享卡信息列表
		 * @param UserId
		 * @return
		 * @throws DataAccessException
		 */
		public List<SharedCardImage> getSharedCardImagelistByUserId(int UserId ) throws DataAccessException;
		
		public int deleteSharedCardImage(SharedCardImage sharedCardImage)throws DataAccessException;
		
		/**
		 * 根据cardid获得封面图片
		 * @param cardid
		 * @return
		 * @throws DataAccessException
		 */
		public SharedCardImage getSharedCardImageByCardId(int cardid) throws DataAccessException;
		
		/**
		 * 根据cardid获得上传最早的照片
		 * @param cardid
		 * @return
		 * @throws DataAccessException
		 */
		public SharedCardImage getMinTimeSharedCardImageByCardId(int cardid) throws DataAccessException;
}
